package org.sixplusone.redblue;

import java.security.SecureRandom;
import java.util.Random;

public class RandomFactory {
	public static Random getRandom(long seed) {
		Random random = new SecureRandom();
		if (seed == 0)
			seed = getSeed();
		random.setSeed(seed);
		return random;
	}

	private static long getSeed() {
		return System.currentTimeMillis();
	}
}
